/* ========== AI视频搜索Agent专用样式 ========== */

/* 平台分类标题 */
.platform-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    margin-top: 24px;
    margin-bottom: 12px;
    border-bottom: 2px solid var(--border-primary);
}

.platform-header h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.platform-count {
    font-size: 0.85rem;
    color: var(--text-muted);
    background: rgba(76, 140, 245, 0.1);
    padding: 4px 12px;
    border-radius: 12px;
}

/* 横向滑动容器 - 胶卷式 */
.videos-scroll-container {
    position: relative;
    margin-bottom: 32px;
    overflow: hidden;
}

.videos-scroll-wrapper {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 16px 4px;
    scrollbar-width: thin;
    scrollbar-color: rgba(76, 140, 245, 0.3) transparent;
}

.videos-scroll-wrapper::-webkit-scrollbar {
    height: 6px;
}

.videos-scroll-wrapper::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
}

.videos-scroll-wrapper::-webkit-scrollbar-thumb {
    background: rgba(76, 140, 245, 0.3);
    border-radius: 3px;
    transition: background 0.3s;
}

.videos-scroll-wrapper::-webkit-scrollbar-thumb:hover {
    background: rgba(76, 140, 245, 0.5);
}

/* 横向视频卡片 - 紧凑版 */
.video-card-horizontal {
    min-width: 180px;
    max-width: 180px;
    background: rgba(28, 28, 28, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-primary);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
}

.video-card-horizontal:hover {
    transform: translateY(-6px) scale(1.02);
    border-color: var(--accent-blue);
    box-shadow: 0 8px 24px rgba(76, 140, 245, 0.3);
}

/* 缩略图容器 - 缩小高度 */
.video-thumbnail-wrapper {
    position: relative;
    width: 100%;
    height: 100px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.5);
}

.video-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.video-card-horizontal:hover .video-thumbnail {
    transform: scale(1.1);
}

.video-duration {
    position: absolute;
    bottom: 6px;
    right: 6px;
    background: rgba(0, 0, 0, 0.85);
    color: white;
    padding: 3px 6px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
}

/* 视频信息区域 - 缩小内边距 */
.video-info-horizontal {
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
}

.video-title-horizontal {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 2.4em;
}

.video-author {
    font-size: 0.75rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 4px;
}

.video-author::before {
    content: '👤';
}

/* 生成笔记按钮 - 紧凑版 */
.btn-generate-notes {
    width: 100%;
    background: linear-gradient(135deg, rgba(76, 140, 245, 0.15) 0%, rgba(90, 156, 247, 0.2) 100%);
    border: 1px solid rgba(76, 140, 245, 0.3);
    color: var(--accent-blue);
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    font-family: inherit;
    margin-top: auto;
}

.btn-generate-notes:hover {
    background: linear-gradient(135deg, rgba(76, 140, 245, 0.25) 0%, rgba(90, 156, 247, 0.3) 100%);
    border-color: var(--accent-blue);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(76, 140, 245, 0.3);
}

.btn-generate-notes:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* 取消生成按钮 */
.btn-cancel-generation {
    flex: 0 0 auto;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15) 0%, rgba(220, 38, 38, 0.2) 100%);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    font-family: inherit;
}

.btn-cancel-generation:hover {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.25) 0%, rgba(220, 38, 38, 0.3) 100%);
    border-color: #ef4444;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

/* 思维链容器 - 完全透明融入响应 */
.thinking-wrapper {
    margin: 0 0 16px 0;
    background: transparent;
    border: none;
    border-radius: 0;
    overflow: visible;
}

.thinking-header {
    display: none;
}

.thinking-toggle {
    display: none;
}

.thinking-container {
    padding: 0;
    max-height: none;
    overflow-y: visible;
    font-size: 0.75rem;
}

.thinking-step {
    margin-bottom: 8px;
    padding: 6px 8px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 4px;
    line-height: 1.5;
    animation: fadeInThinking 0.2s ease-in;
}

.thinking-step:last-child {
    margin-bottom: 0;
}

.thinking-step p {
    margin: 0 0 4px 0;
}

.thinking-step p:last-child {
    margin-bottom: 0;
}

.thinking-step strong {
    color: var(--accent-blue);
    font-weight: 600;
    font-size: 0.8rem;
}

.thinking-step ul {
    margin: 4px 0 0 0;
    padding-left: 16px;
    font-size: 0.72rem;
}

.thinking-step li {
    margin: 2px 0;
    color: var(--text-muted);
}

.thinking-step code {
    background: rgba(0, 0, 0, 0.3);
    padding: 1px 4px;
    border-radius: 2px;
    font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
    font-size: 0.7rem;
    color: #a5d6ff;
}

/* 思维链动画 */
@keyframes fadeInThinking {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 响应式 */
@media (max-width: 768px) {
    .platform-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    .video-card-horizontal {
        min-width: 170px;
        max-width: 170px;
    }
    
    .video-thumbnail-wrapper {
        height: 95px;
    }
    
    .thinking-wrapper {
        margin: 0 0 12px 0;
    }
    
    .thinking-header {
        padding: 6px 10px;
    }
    
    .thinking-title {
        font-size: 0.75rem;
    }
    
    .thinking-container {
        padding: 6px 10px;
        font-size: 0.7rem;
        max-height: 250px;
    }
    
    .thinking-step {
        padding: 5px 6px;
        margin-bottom: 6px;
    }
    
    .thinking-step strong {
        font-size: 0.75rem;
    }
    
    .thinking-step ul {
        font-size: 0.68rem;
        padding-left: 14px;
    }
}
